//
//  HZRemoteResult.h
//  app
//
//  Created by 刘华舟 on 15/5/5.
//  Copyright (c) 2015年 hdaren. All rights reserved.
//

#import "JKResult.h"
#import "JKResponse.h"

@interface HZRemoteResult : JKResult

@property (strong, nonatomic) id tag;
@property (strong, nonatomic) id info;
@property (readonly, nonatomic) JKResponse* response;
@property (readonly, nonatomic) NSDictionary* content;

@property (readonly, nonatomic) BOOL OK;
@property (readonly, nonatomic) BOOL success;
@property (readonly, nonatomic) BOOL failure;

+(id)target:(id)target action:(SEL)action;
+(id)target:(id)target action:(SEL)action tag:(id)tag;
+(id)target:(id)target action:(SEL)action info:(id)info;

-(BOOL)isTail;
-(BOOL)hasMore;

-(HZRemoteResult*)bindTag:(id)tag;
-(HZRemoteResult*)bindInfo:(id)info;

-(void)call:(JKResponse*)response;


-(id)objectForKey:(NSString*)key;
-(id)objectForKey:(NSString*)key nilValue:(id)val;

-(NSDictionary*)dictForKey:(NSString*)key;
-(NSArray*)arrayForKey:(NSString*)key;
-(NSString*)stringForKey:(NSString*)key;
-(NSNumber*)numberForKey:(NSString*)key;

-(NSString*)stringForKey:(NSString*)key nilValue:(NSString*)str;
-(NSNumber*)numberForKey:(NSString*)key nilValue:(NSNumber*)num;


@end
